import largesScreen from "../page/largesScreen.vue";
import MyLogin from "../page/MyLogin.vue";
import tableDetail from "../page/tableDetail.vue";
import largesScreenMonitor from "../page/largesScreen1.vue";
import warehouseLedger from "../page/warehouseLedger.vue";
import healthyList from "../page/healthyList.vue";
import temperatureAndHumidity from "../page/temperatureAndHumidity.vue";
import internalControl from "../page/internalControlLarge.vue";
import Vue from "vue";
import Router from "vue-router";

Vue.use(Router);

export const constantRoutes = [
  {
    path: "/larges",
    name: "largesScreen",
    component: largesScreen,
  },
  {
    path: "/login",
    component: MyLogin,
  },
  {
    path: "/tableDetail",
    component: tableDetail,
  },
  {
    path: "/larges2",
    component: largesScreenMonitor,
  },
  {
    path: "/warehouseLedger",
    component: warehouseLedger,
  },
  {
    path: "/healthyList",
    component: healthyList,
  },
  {
    path: "/temperHumidity",
    component: temperatureAndHumidity,
  },
  {
    path: "/internalControl",
    component: internalControl,
  },
];

export default new Router({
  mode: "history", // 去掉url中的#
  scrollBehavior: () => ({
    y: 0,
  }),
  routes: constantRoutes,
});
